﻿using System;

namespace TFSUtils.Model
{
    public class DataService : IDataService
    {
        public void GetData(Action<TFSBasicData, Exception> callback)
        {
            // Deserilize any data stored            
            TFSBasicData item = Helpers.SerialiseHelper.DeserialiseObject<TFSBasicData>() as TFSBasicData;
            callback(item, null);
        }

        public void SaveData(TFSBasicData data)
        {
            Helpers.SerialiseHelper.SerialiseObject(data);
        }
    }
}